<?php
$con = mysql_connect("localhost","root","root");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }

// some code

mysql_select_db("test", $con);
/*
$result = mysql_query("SELECT * FROM table01");
echo '<table border="1" width="600" align="center">';
echo "<tr><th>id</th><th>english</th><th>chinese</th></tr>";
while($row = mysql_fetch_array($result))
  {
    echo "<tr>";
  echo "<td>".$row['id'] . "</td><td> " .$row['english'] . "</td><td> " . $row['chinese']."</td>";
  //echo "<br />";
  echo "</tr>";
  }
echo "</table>";
*/
  $result2=mysql_query("SELECT MAX(id) as id FROM table01");
  //echo $result2;
  $maxid=mysql_fetch_array($result2);
  print_r( $maxid);
  echo '<table border="1" width="600" align="center">';

while($row2 = mysql_fetch_array($result2))
  {
    echo "<tr>";
    echo "<td>".$row2[0]."</td>"; 
  echo "</tr>";
  }
echo "</table>";
mysql_close($con);
?>